package com.ww.nio.filechannel;

import java.nio.IntBuffer;

public class AllocateDemo {

    static IntBuffer intBuffer = null;

    public static void allocatTest() {
        intBuffer = IntBuffer.allocate(20);
        System.out.println("position = " + intBuffer.position());
        System.out.println("limit = " + intBuffer.limit());
        System.out.println("capacity = " + intBuffer.capacity());
    }

//    position = 0
//    limit = 20
//    capacity = 20
    public static void main(String[] args) {
        allocatTest();
    }
}
